package com.tisumoon.helper;

import android.content.Context;
import android.widget.TextView;

import com.tisumoon.lib.R;
import com.wei.c.utils.TimeUtils;

public class DayNoonHelper {

	public static String getDayNoonForNotification(Context context) {
		return getDayNoonForNotification(context, TimeUtils.getDayNoon());
	}

	public static String getDayNoonForNotification(Context context, int dayNoon) {
		switch (dayNoon) {
		case TimeUtils.DAY_NOON_AM:
			return context.getResources().getString(R.string.notification_text_goodam);
		case TimeUtils.DAY_NOON_NOON:
			return context.getResources().getString(R.string.notification_text_goodnoon);
		case TimeUtils.DAY_NOON_PM:
			return context.getResources().getString(R.string.notification_text_goodpm);
		case TimeUtils.DAY_NOON_EVENING:
			return context.getResources().getString(R.string.notification_text_goodevening);
		case TimeUtils.DAY_NOON_GOOD_NIGHT:
			return context.getResources().getString(R.string.notification_text_goodnight);
		default:
			return context.getResources().getString(R.string.notification_text_goodmorning);
		}
	}

	public static void updateDayNoonHello(TextView textView) {
		updateDayNoonHello(textView, TimeUtils.getDayNoon());
	}

	public static void updateDayNoonHello(TextView textView, int dayNoon) {
		switch (dayNoon) {
		case TimeUtils.DAY_NOON_MORNING:
			textView.setText(R.string.i_f_chitchat_friend_text_goodmorning);
			//textView.setCompoundDrawablesWithIntrinsicBounds(R.drawable.exp_i_f_chitchat_friend_goodmorning, 0, 0, 0);
			break;
		case TimeUtils.DAY_NOON_AM:
			textView.setText(R.string.i_f_chitchat_friend_text_goodam);
			//textView.setCompoundDrawablesWithIntrinsicBounds(left, 0, 0, 0);
			break;
		case TimeUtils.DAY_NOON_NOON:
			textView.setText(R.string.i_f_chitchat_friend_text_goodnoon);
			//textView.setCompoundDrawablesWithIntrinsicBounds(left, 0, 0, 0);
			break;
		case TimeUtils.DAY_NOON_PM:
			textView.setText(R.string.i_f_chitchat_friend_text_goodpm);
			//textView.setCompoundDrawablesWithIntrinsicBounds(left, 0, 0, 0);
			break;
		case TimeUtils.DAY_NOON_EVENING:
			textView.setText(R.string.i_f_chitchat_friend_text_goodevening);
			//textView.setCompoundDrawablesWithIntrinsicBounds(left, 0, 0, 0);
			break;
		case TimeUtils.DAY_NOON_GOOD_NIGHT:
			textView.setText(R.string.i_f_chitchat_friend_text_goodnight);
			//textView.setCompoundDrawablesWithIntrinsicBounds(left, 0, 0, 0);
			break;
		}
	}
}
